<script>
  const { ipcRenderer } = require('electron')

  ipcRenderer.send('request-worker-cannel')

  ipcRenderer.once('provide-worker-channel', (event) => {
    const [ port ] = event.ports
    port.onmessage = (event) => {
      console.info('received result: ', event.data)
    }
    port.postMessage(21)
  })
</script>